#ifndef GUI_H
#define GUI_H

#include "ui_gui.h"
#include "ethernet.h"
#include "servo.h"
#include "physics.h"
#include "motor.h"
#include <QtNetwork>

using std::vector;
 
class Gui : public QMainWindow
{

   Q_OBJECT

  public:
    Gui(QMainWindow *parent = 0);
     
  protected:
    void timerEvent(QTimerEvent*);
   
  private:
    void setThrusters();
    void calcThrust();
    int timeAck;
    
    Ethernet* eth;
    Servo* servo;
    
    quint16 blockSize;
 
    Ui::Gui ui;
    
    Physics *phys;
    Motor *motor;
    
    int timerId;
    
    double thrust1,
           thrust2,
           thrust3,
           vz,
           vy,
           vx,
           joyLat,
           joyFor,
           joySpin,
           depth;
           
    int forward1,
        forward2,
        lateral,
        up1,
        up2,
        up3,
        u1j,
        u2j,
        u3j;
           
    bool connected;
    
    bool useCorrection;
};
#endif
